<template>
	<div class="container">
		<h1>{{ info.title }}</h1>
		<hr>
		<div v-html="info.content" class="content"></div>
	</div>
</template>

<script>
	export default {
		data () {
			return {
				info:{}
			}
		},
		created () {
			this.getGoodinfo()
		},
		methods: {
			getGoodinfo () {
				this.$http.get('http://www.liulongbin.top:3005/api/goods/getdesc/' + this.$route.params.id).then(result => {
					console.log(result.body)
					if (result.body.status === 0) {
						this.info = result.body.message[0]
					}
				})
			}
		}
	}
</script>

<style lang="less">
	.container {
		.content {
			img{
				width: 100%;
			}
		}
	}
</style>